<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<!--引入easyui的样式 -->
<link rel="stylesheet"  type="text/css" href="themes/gray/easyui.css">
<link rel="stylesheet"  type="text/css" href="themes/metro.css">
<!-- js文件 -->
<script type="text/javascript" src="js/jquery.min.js"></script>
<script type="text/javascript" src="js/jquery.easyui.min.js"></script>
<script type="text/javascript" src="js/easyui-lang-zh_CN.js"></script>
<title>宿舍管理系统</title>
</head>
<script type="text/javascript">
$(function(){
	$('#methodTree').tree({    
	    url:'showMethods',
	    queryParams:{"parentId":-1},
	    onLoadSuccess:function(node, data){
	    	$('#methodTree').tree('expandAll');
	    },
	    onClick:function(node){
			if(node.attributes.url){
				if($("#mtabs").tabs('exists',node.text)){
		    		$("#mtabs").tabs('select',node.text)
		    	}else{
		        //选择要连接的路径页面
		        var  pageContent = "<iframe frameborder=0 scrolling='auto' style='width:100%;height:100%' src="+node.attributes.url+"></iframe>";
		    	$("#mtabs").tabs('add',{
		    		 title: node.text,
		    		 closable:true,
		    		 fit:true,
		    		 content:pageContent
		    	})
		    	}
			}
	    }
	});
});
</script>
<body class="easyui-layout" style="margin: 10px 10px 10px 10px">
    <div data-options="region:'north',title:'宿舍管理系统',width:50,height:100,split:true,collapsible:false">
    	<div>
			<script charset="Shift_JIS"
				src="http://chabudai.sakura.ne.jp/blogparts/honehoneclock/honehone_clock_tr.js">
			</script>
		</div>
    </div>
    <div data-options="region:'west',title:'功能展示',width:250,height:50,split:true">
       <ul id="methodTree"></ul>  
    </div>
    <div data-options="region:'center',width:50,height:50,split:true">
    	<div id="mtabs" class="easyui-tabs" border="false" style="width:100%;height:100%;">   
		     <div title="首页" data-options="fit:true">   
		              		欢迎使用本系统   
		      </div>  
		       
   
		</div>  
    	
    </div>
    <div data-options="region:'south',title:'版权所有',width:50,height:100,split:true,collapsible:false"></div>
</body>
</html>